/* dsd.t  DISTRIBUTION ORDER LINE DELETE TRIGGER                      */
/*Copyright 1986-2002 QAD Inc., Carpinteria, CA, USA.                 */
/*All rights reserved worldwide.  This is an unpublished work.        */
/*V8:ConvertMode=NoConvert */
/*********************************************************************/
/*  Program :dsd.t                                                   */
/*  Author  :Ben Holmes                                              */
/*  Date    :01/29/96                                                */
/*  !Description : ds_det DELETE trigger program                     */
/*          : In order to enhance this trigger to support additional */
/*          : interfaces, add a DO-END block similar to the one      */
/*          : used for the Warehousing Interface to (1) check for the*/
/*          : need to continue processing; (2) move the relevant     */
/*          : fields to an appropriate work area; and (3) call       */
/*          : one or more subprograms to continue processing.        */
/*          : This .t program should remain short, relying on        */
/*          : subprograms to perform most of the work.               */
/*********************************************************************/
/*                             MODIFY LOG                            */
/*********************************************************************/
/*Revision 8.5          Last Modified:  01/29/96 BY: BHolmes *J0FY*  */
/*Revision 8.5          Last Modified:  06/25/96 BY: BHolmes *J0M9*  */
/*Revision 8.5          Last Modified:  07/19/96 BY: fwy     *J0MB*  */
/*Revision 8.5          Last Modified:  07/27/96 BY: fwy     *J12B*  */
/*Revision 9.1          Last Modified:  08/11/00 BY: *N0KK* jyn       */
/*                                                                   */
/*                                                                   */
/*                                                                   */
/*********************************************************************/

TRIGGER PROCEDURE FOR DELETE OF DS_DET.

/*J12B*/{mfdeclre.i }


    /* Warehousing Interface processing */

    WI:
    do:

/*J0MB  THIS CODE HAS BEEN DELETED, AS ALL REQUIRED DS_DET
 *      DELETION PROCESSING IS HANDLED BY THE DSW.T TRIGGER AND
 *      ITS SUBPROGRAMS
 *
 *          if not can-find(first whl_mstr where whl_mstr.whl_act no-lock)
 *          then leave.
 *
 *          if ds_det.ds_qty_ord ge 0 then leave.
 *          if    abs(ds_det.ds_qty_ship)
 *            ge abs(ds_det.ds_qty_conf) then leave.
 *
 *          {mfdeclre.i }
 *          define new shared variable w-recid as recid.
 *          define new shared work-table wf_old_ds_det like ds_det.
/*J0M9*/    define new shared variable w-te_type as character.
 *
 *          define variable w-file as character format "x(24)".
 *
 *          assign w-recid = recid(ds_det).
 *          create wf_old_ds_det.
 *          if recid(wf_old_ds_det) = -1 then .
 *          assign
 *              w-te_type                  = "wi-ds-"
 *              wf_old_ds_det.ds_nbr       = ds_det.ds_nbr
 *          wf_old_ds_det.ds_site      = ds_det.ds_site
 *              wf_old_ds_det.ds_shipsite  = ds_det.ds_shipsite
 *          wf_old_ds_det.ds_req_nbr   = ds_det.ds_req_nbr.
/*J0M9*/    wf_old_ds_det.ds_qty_conf  = ds_det.ds_qty_conf.
 *
 *          w-file = "widsd.p".
 *          {gprun.i ""widsd.p""}
 *J0MB*/

/*J12B*/end. /* WI */
